package pkg.networking;
import java.util.Calendar;
import java.util.logging.*;
public class LogFormat extends Formatter{

	@Override
	public String format(LogRecord log) {
		StringBuilder build = new StringBuilder();
		build.append(log.getLevel());
	    build.append(": ").append(log.getMessage()).append('\n');
		if(log.getLevel() == Level.FINE)
			build.append("Thread: ").append(Thread.currentThread().getName());
		return build.toString();
	}
	public String getHead(Handler h) {
	
		return "Log Created at " + Calendar.getInstance().getTime().toString() + "\n";
	}
	
	public String getTail(Handler h) {
         return "";
    }
}
